<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<%@include file="/includes.jsp"%>

<h1 class="layout">Edit Contact Detail Types</h1>

<html:errors/>

<html:form action="contactdetailtypes.do?method=edit" method="post">
    <table class="styled" cellspacing="0">
        <tr>
            <th class="styled">Type Name</th>
            <th class="styled">Notification Mechanism</th>
            <th class="styled">Show Type</th>
            <th class="styled">Show In Directory</th>
            <th class="styled">Insert</th>
            <th class="styled">Delete</th>
            <th class="styled">Move</th>
        </tr>
        <logic:iterate name="contactDetailTypeValueActionForm" property="contactDetailTypeList" id="contactDetailTypeList">
            <logic:notEmpty name="contactDetailTypeList" property="contactDetailTypeId">
                <html:hidden name="contactDetailTypeList" indexed="true" property="contactDetailTypeId"/>
            </logic:notEmpty>
            <tr>
                <td class="styled">
                    <html:text name="contactDetailTypeList" indexed="true" property="typeName" size="30"/>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:select name="contactDetailTypeList" indexed="true" property="notificationId">
                        <html:options collection="notificationPairs" property="integer" labelProperty="string"/>
                    </html:select>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:checkbox name="contactDetailTypeList" indexed="true" property="isShown"/>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:checkbox name="contactDetailTypeList" indexed="true" property="isShownInDirectory"/>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:submit indexed="true" property="cmd" value="Insert"/>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:submit indexed="true" property="cmd" value="Delete"/>
                </td>
                <td class="styled" style="text-align: center;">
                    <html:submit indexed="true" property="cmd" value="Move Up"/>
                </td>
            </tr>
        </logic:iterate>
    </table>
    <div class="buttons">
        <html:submit property="btnSubmit" value="OK"/>
        <html:cancel property="btnSubmit" value="Cancel"/>
    </div>
</html:form>
